CUBE CONNECT Edition Help

Theory

This section discusses topics related to the theory used in the Highway program. These include:

Process overview

It is important to have a basic understanding of the logic of the program, so that when certain special operations are to be performed, they can be placed properly. Although you can place phases in the script in any order, Bentley suggests that you use a basic template for all applications. If you use a basic template, then only the actual operations of each segment need be completed.

Example of suggested basic application template

RUN PGM=HIGHWAY
FILEI
FILEO
FUNCTION       ; include V, TC, and COST functions here
PHASE=SETUP    ; normally this phase is not used
...
PHASE=LINKREAD ; insert any statements required to:
         ; extract custom information from the input network.
...
PHASE=ILOOP ; build paths, skim paths, load trips to paths
...
PHASE=ADJUST ; revise special LW.values for next iteration
...
PHASE=CONVERGE ; optional for user specified convergence tests
...
ENDRUN

The internal logic of the program is as follows:

  • PHASE = SETUP

    • Establish user SET arrays, etc. This phase is not specified by most users. If there is a PHASE=SETUP block, perform the statements of the block.

    • ENDPHASE

  • PHASE = LINKREAD

    • Loop LINKNO=1,NUMLINKS

      • Read each link record.

      • If there is a user supplied LINKREAD block, process it, then set the required values that LINKREAD did not set properly + Set the Time and Cost values

    • EndLoop

    • ENDPHASE

  • LOOP ITERATION=1,MAXITERS

  • PHASE = ILOOP

    • Loop I=1,ZONES

      • Read required MATIs.

      • Process the ILOOP stack.

      • Write requested MATOs.

    • EndLoop

    • ENDPHASE

  • PHASE = ADJUST

    • Loop LINKNO=1,NUMLINKS

      • Read each link record.

      • Obtain link values using most of the LINKREAD process

      • Apply the appropriate Functions ( V, TC, COST ) for the link.

      • Process the user’s ADJUST stack to either list the results of the assignment, or to revise LW.values, or Time for the next iteration.

      • Apply Function Cost.

    • EndLoop.

    • Depending upon the values for COMBINE and ITERATION:

      • Combine link volumes.

      • Combine MATO matrices.

    • Process the CONVERGE stack (user or default)

    • If Convergence met, exit ITERATION Loop.

    • ENDPHASE

  • ENDLOOP ; Iteration loop

Stochastic traffic assignment theory

This section provides theoretical background on the Probit and Burrell stochastical traffic assignment methods. After applying either of these methods during an iteration, Highway will find an All or Nothing Path based on the current congestion level. The stochastic assignment methods use Method of Successive Averages (MSA), for combining the volumes from the different iterations. Users are recommended to run considerable number of iterations to achieve reasonable convergence.

Burrell’s method and Probit method are described below, or, you may skip ahead to All or Nothing Path.

Burrell’s method

The travelers’ perceived travel cost follows a Uniform Distribution of the individual link cost, where the mean of the link cost and variance is supplied by the user.

  • The loading process is based on perturbing link cost values used in path building away from the mean value (input by user), which gives rise to one sample set of paths for each origin. It generates one path per OD pair at each iteration based on the uniformly distributed link cost.

Probit method

The travelers’ perception error follows a Normal Distribution, where the random perceived link cost has mean equal to the measured link travel cost and its variance is proportional to the measured link travel cost. The proportional parameter can also be controlled by the user.

  • The probit-based stochastic assignment is able to alleviate the drawbacks of logit-based stochastic assignment (i.e., the inability to account for correlations between alternatives? utilities, and the inability to account for perception variance with respect to trips of different costs.), and provides reasonable results.

  • Probit-Loading process is simple, and it does not require the sampling of the perceived path travel times; only perceived link travel times are sampled at each iteration thus avoiding path enumeration. Probit-loading process requires higher computational time than the logit-based loading based on Dial’s method. At the price of high computational time, it provides reasonable results.

All or Nothing Path

Last, during each iteration, the algorithm finds an All or Nothing path based on the current congestion level (sampled based on link travel time’s mean and variance restricted by the user specified spread factor). This avoids the requirement to explicitly generate path. In CUBE, the spread factor is controlled by SPREADPERC and SPREADPERCVAR, and the stability of the random sample are ensured by LINKRANDSERIES (i.e. bind the sample with given network and make the results repeatable).

Now if LINKRANDSERIES is true, then STOCHASTICSEED must be set to a constant value, otherwise you will get random results. If STOCHASTICSEED is not specified, then it takes a default value of 1. If LINKRANDSERIES is false and STOCHASTICSEED is not specified, then it is defaulted to a random seed based on the current time. Basically one can have random result, for which you will not set LINKRANDSERIES and STOCHASTICSEED. If you want consistent results, then you will have to set LINKRANDSERIES and STOCHASTICSEED. If you set STOCHASTICSEED only, then you will get exact same result if there is no change in the network.

User stacks

These are stacks of control statements that you provide to perform certain operations at various times in the process. The term stack, as used here, means all the user supplied statements for the phase. Stack and phase are sometimes used interchangeably. Phase refers to a phase the program automatically processes, and stack refers to the user supplied statement for that phase. The ILOOP stack is required, but all the others are optional. Most times, the other stacks will not be necessary, but it does provide a mechanism for altering program variable values at crucial times. Each stack begins with a PROCESS PHASE = StackName statement. (PHASE is a trigger key, so most users will just code PHASE= without the leading control word.) The operational statements that are to be preformed in this stack follow the PHASE statement. The stack is terminated by the presence of another PHASE = stackname statement, an ENDPHASE statement, or the end of input. Non-operational statements (FILEI, FILEO, PARAMETERS, FUNCTION and others) can be within a stack, but they are ignored during stack processing. It is suggested that all non-operational statements be placed at the beginning of the input for reader clarification. Each of the phases, may be specified one time only. IF and LOOP blocks must be complete within a stack, and GOTO and associated label statements must be within the same stack. EXIT and ABORT will cause termination of a stack, but will have impact on the actual program process only from ILOOP.

LINKREAD stack

This stack is in the LINKREAD phase, and is used as explained above in that section. Primarily, it is used to obtain required link values (if they are not directly available from the input network), and to set link LW.values and GROUP codes.

ILOOP stack

This stack is the entire ILOOP phase, and is described previously. It MUST be present.

ADJUST stack

This stack is processed as the last operation in the ADJUST phase link loop. It provides a place for computing and accumulating special values such as objective functions (currently undocumented). It also provides the capability to print certain link values during the process. If LW.values are dependent upon Time and/or Cost, and it is necessary to reflect the changes in those values to the LW.values for the next iteration, the adjustment can be made here. Alternatively, the LW.values can be adjusted with ILOOP statements.

CONVERGE stack

This stack is processed during convergence testing in the ADJUST phase. Its primary purpose is to set BALANCE to 1 if certain conditions are met. Most users will not have any need for this stack.